package com.test39_集合应用.vo;

import java.util.LinkedHashSet;
import java.util.Set;

/**
 * 雇员
 */
public class Emp {
    private Long empno;
    private String ename;
    private Dept dept;
    private Set<String> business;   // 业务信息，不会有重复内容

    public Emp() {
        this(null, null);
    }

    public Emp(Long empno, String ename) {
        this.empno = empno;
        this.ename = ename;
        this.business = new LinkedHashSet<>();
    }

    public Long getEmpno() {
        return empno;
    }

    public void setEmpno(Long empno) {
        this.empno = empno;
    }

    public String getEname() {
        return ename;
    }

    public void setEname(String ename) {
        this.ename = ename;
    }

    public Dept getDept() {
        return dept;
    }

    public void setDept(Dept dept) {
        this.dept = dept;
    }

    public Set<String> getBusiness() {
        return business;
    }

    public void setBusiness(Set<String> business) {
        this.business = business;
    }

    @Override
    public String toString() {
        return "【Emp】雇员编号：" + this.empno + "、姓名：" + this.ename + "、业务：" + this.business;
    }
}
